package GUI_Data.FlightSeatPanel;

import Data_Structure.DataImplement.Flight;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.swing.*;
//The class Boeing737Panel and AirbusA320Panel may be mixed together in this class.
/**
 * The general panel of seat choosing.This class may should be changed into interface.
 *
 * @author Xiaorun Wang
 * @since 9 April 2022
 * @version 1.0
 */
@EqualsAndHashCode(callSuper = true)
@Data
public class FlightSeatPanel extends JPanel {
    private Flight.PlaneType planeType;
    /**
     * This method need to be overridden by child classes, for seat selecting
     * @param seatButton The seat selected.
     */
    public void seatSelect(SeatButton seatButton){

    }

    /**
     * This method need to be overridden by child classes, for seat selecting confirming.
     * @return Success for true and false for false
     */
    public SeatButton confirmChange(){
        return null;
    }

    /**
     * This method need to be overridden by child classes, for returning to last selection.
     */
    public void returnBack(){

    }

    public void changeButtonColor(SeatButton seatButton){}

}
